<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Logger{
	static function getInstance(){
		if (self::$instance == NULL){
			self::$instance = new Logger();
		}
		return self::$instance;
	}
	
	public function __construct(){
	}
	
	private function __clone(){
	}
	
	function log($class, $text = 'standart checkpoint'){
		$fh = fopen("logs/".$class.".log", "a+");
		fwrite($fh,  date('Y-m-d H:i:s  ').$text."\n");
		fclose($fh);
	}
	static private $instance = NULL;
}
?>